-------------- store pro khach hang -------------------
if exists (select name from sysobjects where name like 'Proc_LoaiKH_GetById')
	drop procedure Proc_LoaiKH_GetById
go

create PROC Proc_LoaiKH_GetById (@maLoaiKH int )
as
	select * from LoaiKH
	where @maLoaiKH= LoaiKH.MaLoai
go

Exec Proc_LoaiKH_GetById 1
go

----------------------------------------
if exists (select name from sysobjects where name like 'Proc_LoaiKH_GetALL')
	drop procedure Proc_LoaiKH_GetALL
go

create PROC Proc_LoaiKH_GetALL ( @delFlg int )
as
	select * from LoaiKH
	where @delFlg = DelFlg
go

Exec Proc_LoaiKH_GetALL 0
go
